<!DOCTYPE html>
<html>
<head>
	<meta charset="UTF-8">
	<base href="/">
	<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
	<title>普通资产管理</title>
</head>
<body>
	<div class="container-fluid">
		<div class="row">
			<div id="divSearchForm" class="col-md-10">
				<div>
					<label for="spanCategoryGroup">资产分类：</label>
					<span id="spanCategoryGroup">
						<select id="selCategory1" ><option value="-1">全部</option></select>
						<select id="selCategory2" ><option value="-1">全部</option></select>
					</span>
				</div>
				<div>
					<label for="tbxAssetsName">资产名称：</label>
					<input type="text" id="tbxAssetsName"  />
				</div>
				<div>
					<label for="tbxAssetsCode">资产编号：</label>
					<input type="text" id="tbxAssetsCode" />
				</div>
				<div>
					<label for="selFinanceType">金融资产类型：</label>
					<select id="selFinanceType"><option value="-1">全部</option></select>
				</div>
				<div>
					<label for="tbxOrganization">托管机构：</label>
					<input type="text" id="tbxOrganization" />
				</div>
				<div>
					<label for="tbxRefBankNo">关联账号：</label>
					<input type="text" id="tbxRefBankNo" />
				</div>
				<div>
					<label for="ckbAutoCycle">自动续期：</label>
					<input type="checkbox" id="ckbAutoCycle"/>
				</div>
				<div>
					<button type="button" id="btnSearch" class="btn-primary">
						<span class="glyphicon glyphicon-search" />
						检索Search
					</button>
				</div>
			</div>
		</div>
		<div class="row">
			<div class="col-md-10">
				<div id="toolsButtons">
					<button type="button" id="btnAdd" class="btn-success">
						<span class="glyphicon glyphicon-plus" />
						新增金融资产 Add
					</button>
					<button type="button" id="btnInstockShow" class="btn-primary">
						<span class="glyphicon glyphicon-download-alt" />
						金融资产登记  Instock
					</button>
					<button type="button" id="btnEdit" class="btn-warning">
						<span class="glyphicon glyphicon-edit" />
						编辑金融资金信息 Edit
					</button>
				</div>
			</div>
		</div>
		<div class="row">
			<div class="col-md-10">
				<div id="divResult">
					<table id="tblResult">
						<thead>
							<tr id="resultHeader">
								<th data-halign="center" data-valign="middle">
									<span class="glyphicon glyphicon-tags" />
									资产编号
								</th>
								<th data-halign="center" data-valign="middle">资产名称</th>
								<th data-halign="center" data-valign="middle">托管机构</th>
								<th data-halign="center" data-valign="middle">关联账号</th>
								<th data-halign="center" data-valign="middle">期限（月）</th>
								<th data-halign="center" data-valign="middle">库存记录</th>
							</tr>
						</thead>
						<tbody id="resultBody"></tbody>
					</table>
				</div>
			</div>
		</div>
	</div>
	<!-- 信息编辑窗口 -->
	<div id="divAssetsInfo" tabindex="-1" role="dialog" aria-labelledby="assetsInfoTitle" aria-hidden="true">
		<div class="modal-dialog">
			<div id="assetsInfoContent" class="modal-content">
				<div id="AssetsInfoHead" class="modal-header">
					<button type="button" class="close" data-dismiss="modal" aria-hidden="true">
						&times;
					</button>
					<h4 class="modal-title" id="assetsInfoTitle"><span class="glyphicon glyphicon-equalizer"></span> 资产信息 </h4>
				</div>
				<div class="modal-body">
					<form id="formAssetsInfo">
						<input type="hidden" id="hidAssetsId" value="" />
						<div id="divEditAlert" role="alert"></div>
						<div id="divEditContent">
							<div>
								<label for="tbxAssetsCodeEdit">资产编号：</label>
								<div class="input-group">
									<input type="text" id="tbxAssetsCodeEdit" readonly="readonly" />
								</div>
							</div>
							<div>
								<label for="tbxAssetsNameEdit">资产名称：</label>
								<div class="input-group">
									<input type="text" id="tbxAssetsNameEdit" required="required" />
									<span class="input-group-addon" >
										<span class="glyphicon glyphicon-asterisk"></span>
									</span>
								</div>
							</div>
							<div>
								<label for="spanCategoryGroupEdit">资产分类：</label>
								<div class="input-group">
									<div>
											<select id="selCategoryEdit1" required="required" ></select>
											<select id="selCategoryEdit2" required="required" ></select>
									</div>
								</div>
							</div>
							<div>
								<label for="selFinanceTypeEdit">资产形式：</label>
								<div class="input-group">
									<select id="selFinanceTypeEdit"></select>
								</div>
							</div>
							<div>
								<label for="tbxOrganizationEdit">托管机构：</label>
								<div class="input-group">
									<input type="text" id="tbxOrganizationEdit" required="required" />
									<span class="input-group-addon" >
										<span class="glyphicon glyphicon-asterisk"></span>
									</span>
								</div>
							</div>
							<div>
								<label for="tbxRefBankNoEdit">关联账号：</label>
								<div class="input-group">
									<input type="text" id="tbxRefBankNoEdit" required="required" />
									<span class="input-group-addon" >
										<span class="glyphicon glyphicon-asterisk"></span>
									</span>
								</div>
							</div>
							<div>
								<label for="tbxUnitAmountEdit">金额下限（万元）：</label>
								<div class="input-group">
									<span class="input-group-addon">￥</span>
									<input type="number" min="0" id="tbxUnitAmountEdit" required="required" />
									<span class="input-group-addon" >
										<span class="glyphicon glyphicon-asterisk"></span>
									</span>
								</div>
							</div>
							<div>
								<label for="tbxCycleEdit">托管周期（月）：</label>
								<div class="input-group">
									<input type="number" min="0" id="tbxCycleEdit" required="required" />
									<span class="input-group-addon" >
										<span class="glyphicon glyphicon-asterisk"></span>
									</span>
								</div>
							</div>
							<div>
								<label for="ckbAutoCycleEdit">自动续期：</label>
								<div class="input-group">
									<input type="checkbox" id="ckbAutoCycleEdit" required="required" />
								</div>
							</div>
							<div>
								<label for="tbxCommentEdit">其他说明：</label>
								<div class="input-group">
									<textarea rows="2" id="tbxCommentEdit"></textarea>
								</div>
							</div>
						</div>
					</form>
				</div>
				<div class="modal-footer">
					<button class="btn-primary" id="btnSaveAssets">
							<span class="glyphicon glyphicon-floppy-saved" /> 保存 Save</button>
					<button class="btn-default" data-dismiss="modal" id="btnCancel">
							<span class="glyphicon glyphicon-remove" /> 取消 Cancel</button>
				</div>
			</div>
		</div>
	</div>
	<!-- 资产入库操作 -->
	<div id="divAssetsInstock"  tabindex="-1" role="dialog" aria-labelledby="assetsInstockTitle" aria-hidden="true">
		<div class="modal-dialog">
			<div id="content" class="modal-content">
				<div id="assetsInstockHead" class="modal-header">
					<button type="button" class="close" data-dismiss="modal" aria-hidden="true">
						&times;
					</button>
					<h4 class="modal-title" id="assetsInstockTitle"><span class="glyphicon glyphicon-equalizer"></span>金融资产登记 </h4>
				</div>
				<div class="modal-body">
					<form id="formInstock">
						<input type="hidden" id="hidAssetsIdForInstock" value="" />
						<input type="hidden" id="hidCycle" value="" />
						<div id="divInstockAlert" role="alert"></div>
						<div id="divInstockContent">
							<div>
								<label for="tbxAssetsNameShow">资产名称：</label>
								<div class="input-group">
									<input type="text" id="tbxAssetsNameForInstock" readonly="readonly" />
								</div>
							</div>
							<div>
								<label for="tbxInstockCount">预期收益率：</label>
								<div class="input-group">
									<span class="input-group-addon">%（年化）</span>
									<input type="number" min="0" id="tbxInstockCount" required="required" />
									<span class="input-group-addon" >
										<span class="glyphicon glyphicon-asterisk" ></span>
									</span>
								</div>
							</div>
							<div>
								<label for="tbxInstockPrice">实际单位金额：</label>
								<div class="input-group">
									<span class="input-group-addon">￥（万元）</span>
									<input type="number" min="0" id="tbxInstockPrice" required="required" />
									<span class="input-group-addon" >
										<span class="glyphicon glyphicon-asterisk" ></span>
									</span>
								</div>
							</div>
							<div>
								<label for="tbxInstockSum">金额合计：</label>
								<div class="input-group">
									<span class="input-group-addon">￥（万元）</span>
									<input type="text" readonly="readonly" min="0" id="tbxTotalPrice" />
								</div>
							</div>
							<div>
								<label for="tbxInstockDate">登记时间：</label>
								<div class="input-group">
									<input type="date" id="tbxInstockDate" required="required" />
									<span class="input-group-addon" >
										<span class="glyphicon glyphicon-asterisk" ></span>
									</span>
								</div>
							</div>
							<div>
								<label for="selHandlerEmp">资产购置人：</label>
								<div class="input-group">
									<select id="selHandlerEmp" required="required"></select>
								</div>
							</div>
							<div>
								<label for="tbxInstockComment">备注说明：</label>
								<div class="input-group">
									<textarea rows="2" id="tbxInstockComment"></textarea>
								</div>
							</div>
						</div>
					</form>
				</div>
				<div class="modal-footer">
					<button class="btn-primary" id="btnInstock">
							<span class="glyphicon glyphicon-save" /> 入库 Instock</button>
					<button class="btn-default" data-dismiss="modal" id="btnCancelInstock">
							<span class="glyphicon glyphicon-remove" /> 取消 Cancel</button>
				</div>
			</div>
		</div>
	</div>
	<!-- 物流信息窗口 -->
	<div id="divTransHistory" tabindex="-1" role="dialog" aria-labelledby="assetsInstockTitle" aria-hidden="true">
		<div class="modal-dialog modal-lg">
			<div id="content" class="modal-content">
				<div id="transHistoryHead" class="modal-header">
					<button type="button" class="close" data-dismiss="modal" aria-hidden="true">
						&times;
					</button>
					<h4 class="modal-title" id="transHistoryTitle"><span class="glyphicon glyphicon-equalizer"></span>资产流转记录 </h4>
				</div>
				<div class="modal-body">
					<table id="tblTransHistory">
					</table>
				</div>
				<div class="modal-footer">
					<div id="divAssetsStocking">
						合计入库数量：<span id="spanInstockCount"></span>
						合计出库数量：<span id="spanDeliveryCount"></span>
						当前库存合计：<span id="spanStockCount"></span>
					</div>
				</div>
			</div>
		</div>
	</div>
</body>
<script type="text/javascript" src="js/bower_components/requirejs/require.js" data-main="js/logic/financeAssets"></script>
</html>